/*   Shotscreens
 *   Copyright (C) 2010, Vadim Zakondyrin (http://crystalnix.com)
 *
 *   This program is free software: you can redistribute it and/or modify
 *   it under the terms of the GNU General Public License as published by
 *   the Free Software Foundation, either version 3 of the License, or
 *   (at your option) any later version.
 *
 *   This program is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU General Public License for more details.
 *
 *   You should have received a copy of the GNU General Public License
 *   along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

#include "authorizationmenu.h"
#include "ui_authorizationmenu.h"

AuthorizationMenu::AuthorizationMenu(QWidget *parent) :
        QDialog(parent), ui(new Ui::authorizationmenu) {

    ui->setupUi(this);
    connect(ui->closeButton, SIGNAL(clicked()), this, SLOT(close()));

}

AuthorizationMenu::~AuthorizationMenu()
{
    delete ui;
}

QString AuthorizationMenu::getLogin()
{
    return ui->loginLineEdit->text();
}

QString AuthorizationMenu::getPassword()
{
    return ui->passwordLineEdit->text();
}

void AuthorizationMenu::setLogin(const QString &login)
{
    ui->loginLineEdit->setText(login);
}

void AuthorizationMenu::setPassword(const QString &password)
{
    ui->passwordLineEdit->setText(password);
}

QString AuthorizationMenu::getUploader()
{
    return ui->uploadersComboBox->currentText();
}

void AuthorizationMenu::setUploader(const QString &uploader)
{
    ui->uploadersComboBox->setEditText(uploader);
}
